﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;

namespace sign_recognition
{
    public partial class ClassifyForm : Form
    {
        public FuzzyART fuzzyART;
        public ClassifyForm()
        {
            InitializeComponent();
        }

        private void ClassifyForm_Load(object sender, EventArgs e)
        {
           // FuzzyART f= new FuzzyART(
        }

        private void button1_Click(object sender, EventArgs e)
        {
            //this.getInput(1), false, 0.1, 0.9, 1
            OpenFileDialog openFileDialog = new OpenFileDialog();
            openFileDialog.ShowDialog();
            if (null!=openFileDialog.FileName)
            {
                //FuzzyART f = new FuzzyART(240 * 320, false, 0.1, 0.9, 1, openFileDialog.FileName);
                fuzzyART = new FuzzyART(4, true, 0.1, 0.9, 1, openFileDialog.FileName);
            }

        }

        private void button2_Click(object sender, EventArgs e)
        {
            Double[] input= new Double[4];
            input[0]=0.3;
            input[1]=0.4;
            input[2]=0.6;
            input[3]=0.6;
            /*
             *  input[0] = 0.3;
                input[1] = 0.4;
                input[2] = 0.6;
                input[3] = 0.4;
             * */
            MessageBox.Show(this.fuzzyART.clasify(input).ToString());
        }
    }
}
